void datasetTXT(TString file = "myfile.txt", TString dataSetName = "local", TString proofMasterName = "skaf.saske.sk" , TString defaultTree = "")
{
  Bool_t doRecreate = kTRUE;

  gEnv->SetValue("XSec.GSI.DelegProxy", "2");
  if (!TProof::Open(proofMasterName.Data())) {
    Error("datasetTXT.C", Form("Could not connect to %s !!!", proofMasterName.Data()));
    return;
  }

  TFileCollection *coll = gProof->GetDataSet(dataSetName.Data());

  if (coll || doRecreate) {
    gProof->RemoveDataSet(dataSetName.Data());
    coll = new TFileCollection(dataSetName.Data());
  }
  
  if (!coll) {
    Error("datasetTXT.C", "coll is still null !!!");
    return;
  }

  coll->AddFromFile(file.Data());

  gProof->RegisterDataSet(dataSetName.Data(),coll);
  gProof->ShowDataSets();
  if (!defaultTree.IsNull())
    gProof->SetDataSetTreeName(dataSetName.Data(),defaultTree.Data());
  gProof->VerifyDataSet(dataSetName.Data());
  gProof->ShowDataSets();

}
